#ifndef __COMMON_FUNCTION_H__
#define __COMMON_FUNCTION_H__

#ifdef __cplusplus
extern "C" 
{
#endif

#include <stdio.h>
#include <string.h>
#include <WinSock2.h>
	
#include "tcSockMacros.h"
#include "tcCreateClient.h"

__declspec(dllexport) int tc_socket_cf_process_msg(int recv_len, char *msg, char *tag, char *content);

// return 0 for normal, other for error code
__declspec(dllexport) int tc_socket_cf_login(ClientOpt * opt);

__declspec(dllexport) int tc_socket_cf_exit_game(ClientOpt * opt);
__declspec(dllexport) int tc_socket_cf_get_user_list(ClientOpt * opt);
__declspec(dllexport) int tc_socket_cf_connect_user(ClientOpt * opt, char * guest_name);
__declspec(dllexport) int tc_socket_cf_send_data(ClientOpt * opt, void * data, int len);
__declspec(dllexport) int tc_socket_cf_send_info(char * server_name, int port, void * content, int len);

#ifdef __cplusplus
}
#endif

#endif